home *** CD-ROM | disk | FTP | other *** search
/ Atari Mega Archive 1 / Atari Mega Archive - Volume 1.iso / lists / mint / l_1599 / 1546 < prev    next >
Encoding:
Internet Message Format  |  1994-08-27  |  10.2 KB

  1. From: Julian Reschke <reschke@GOEDEL.UNI-MUENSTER.DE>
  2. Subject: Pure diffs
  3. Date: Wed, 8 Jun 94 15:19:56 MET DST
  4.  
  5. diff --recursive --unified /mint/biosfs.c /mymint/biosfs.c
  6. --- /mint/biosfs.c    Wed Jun  8 13:51:36 1994
  7. +++ /mymint/biosfs.c    Sun Jun  5 14:18:02 1994
  8. @@ -825,7 +825,7 @@
  9.                   */
  10.                  struct tty *ttyptr;
  11.  
  12. -                if (!(ttyptr = kmalloc(SIZEOF(struct tty))))
  13. +                if (NULL == (ttyptr = kmalloc(SIZEOF(struct tty))))
  14.                      return ENSMEM;
  15.                  b->tty = ttyptr;
  16.              }
  17. @@ -1971,7 +1971,7 @@
  18.              return 0;
  19.          }
  20.  /* special code for opening a tty */
  21. -        if ((tty = (struct tty *)f->devinfo)) {
  22. +        if (NULL != (tty = (struct tty *)f->devinfo)) {
  23.              extern struct tty default_tty;    /* in tty.c */
  24.  
  25.              /* first open for this device? */
  26. diff --recursive --unified /mint/dos.c /mymint/dos.c
  27. --- /mint/dos.c    Wed Jun  8 13:51:44 1994
  28. +++ /mymint/dos.c    Sun Jun  5 14:18:02 1994
  29. @@ -239,6 +239,8 @@
  30.  p_getauid(id)
  31.      int id;
  32.  {
  33. +    UNUSED(id);
  34. +
  35.      return curproc->auid;
  36.  }
  37.  
  38. @@ -246,6 +248,8 @@
  39.  p_setauid(id)
  40.      int id;
  41.  {
  42. +    UNUSED(id);
  43. +
  44.      if (curproc->auid)
  45.          return EACCDN;
  46.  
  47. @@ -258,6 +262,8 @@
  48.      int gidsetlen;
  49.      int gidset[];
  50.  {
  51. +    UNUSED(gidsetlen); UNUSED(gidset);
  52. +
  53.      return 0;
  54.  }
  55.  
  56. @@ -266,6 +272,8 @@
  57.      int ngroups;
  58.      int gidset[];
  59.  {
  60. +    UNUSED(ngroups); UNUSED(gidset);
  61. +
  62.      return EACCDN;
  63.  }
  64.  
  65. diff --recursive --unified /mint/dosdir.c /mymint/dosdir.c
  66. --- /mint/dosdir.c    Wed Jun  8 13:51:46 1994
  67. +++ /mymint/dosdir.c    Sun Jun  5 14:18:02 1994
  68. @@ -731,17 +731,17 @@
  69.  {
  70.  #if 0
  71.      fcookie dir, fc;
  72. +    XATTR    xattr;
  73.  #else
  74.      fcookie dir;
  75.  #endif
  76.      long r;
  77.      char temp1[PATH_MAX];
  78. -    XATTR    xattr;
  79.  
  80.      TRACE(("Fdelete(%s)", name));
  81.  
  82.  /* get a cookie for the directory the file is in */
  83. -    if (( r = path2cookie(name, temp1, &dir) ))
  84. +    if (E_OK != ( r = path2cookie(name, temp1, &dir) ))
  85.      {
  86.          DEBUG(("Fdelete: couldn't get directory cookie: error %ld", r));
  87.          return r;
  88. diff --recursive --unified /mint/dosfile.c /mymint/dosfile.c
  89. --- /mint/dosfile.c    Wed Jun  8 13:51:48 1994
  90. +++ /mymint/dosfile.c    Sun Jun  5 14:19:32 1994
  91. @@ -1027,7 +1027,7 @@
  92.              f = p->handle[i];
  93.              if ((*f->dev->select)(f, (long)p, O_RDONLY) == 1 ||
  94.                  (is_terminal(f) &&
  95. -                (scan = (tty=(struct tty *)f->devinfo)->state & TS_ESC) &&
  96. +                0 != (scan = (tty=(struct tty *)f->devinfo)->state & TS_ESC) &&
  97.                  (tty->xkey ? tty->xkey[scan] :
  98.                      vt52xkey[scan]))) {
  99.                  count++;
  100. diff --recursive --unified /mint/dosmem.c /mymint/dosmem.c
  101. --- /mint/dosmem.c    Wed Jun  8 13:51:52 1994
  102. +++ /mymint/dosmem.c    Sun Jun  5 14:18:02 1994
  103. @@ -772,7 +772,7 @@
  104.              if (tty->use_cnt > 1) {
  105.                  for (p = proclist; p; p = p->gl_next) {
  106.                      if (p->pgrp == pgrp && p != curproc &&
  107. -                        ((pfp = p->control)) &&
  108. +                        (0 != (pfp = p->control)) &&
  109.                          pfp->fc.index == fp->fc.index &&
  110.                          pfp->fc.dev == fp->fc.dev)
  111.                          goto found;
  112. @@ -787,6 +787,7 @@
  113.              tty->pgrp = 0;
  114.          }
  115.  found:
  116. +        ;
  117.      }
  118.  #endif
  119.  
  120. diff --recursive --unified /mint/main.c /mymint/main.c
  121. --- /mint/main.c    Wed Jun  8 13:52:04 1994
  122. +++ /mymint/main.c    Sun Jun  5 14:18:02 1994
  123. @@ -1380,13 +1380,13 @@
  124.          return;
  125.      }
  126.      if (!strcmp (cmd, "include")) {
  127. -        int fd = f_open (arg1, 0);
  128. +        long fd = f_open (arg1, 0);
  129.          if (fd < 0) {
  130.          ALERT ("include: cannot open file %s", arg1);
  131.          return;
  132.          }
  133. -        do_file (fd);
  134. -        f_close (fd);
  135. +        do_file ((int) fd);
  136. +        f_close ((int) fd);
  137.          return;
  138.      }
  139.      arg2 = line;
  140. diff --recursive --unified /mint/memprot.c /mymint/memprot.c
  141. --- /mint/memprot.c    Tue Sep 14 17:48:20 1993
  142. +++ /mymint/memprot.c    Sun Jun  5 14:18:02 1994
  143. @@ -388,6 +388,8 @@
  144.      long_desc *tbl, *tbl_b, *tbl_c;
  145.      ulong oldlen;
  146.  
  147. +    UNUSED(proc);
  148. +
  149.      if (no_mem_prot) return;
  150.  
  151.      oldlen = len;
  152. @@ -399,9 +401,9 @@
  153.       * d_index is the 8K number within that 1MB (0-127).
  154.       */
  155.  
  156. -    b_index = (start >> LOG2_16_MEG);
  157. -    c_index = (start >> LOG2_ONE_MEG) & 0xf;
  158. -    d_index = (start >> LOG2_EIGHT_K) & 0x7f;
  159. +    b_index = (int)(start >> LOG2_16_MEG);
  160. +    c_index = (int)((start >> LOG2_ONE_MEG) & 0xf);
  161. +    d_index = (int)((start >> LOG2_EIGHT_K) & 0x7f);
  162.  
  163.      /* precompute the table addresses */
  164.      tbl_b = &base_tbl[0].tbl_address[b_index];
  165. @@ -1137,6 +1139,8 @@
  166.      tbl.tbl_address = proc->ctxt[CURRENT].crp.tbl_address;
  167.      _dump_tree(tbl,0);
  168.      }
  169. +#else
  170. +    UNUSED(proc); UNUSED(bigone);
  171.  #endif /* DEBUG_INFO */
  172.  }
  173.  
  174. diff --recursive --unified /mint/proc.c /mymint/proc.c
  175. --- /mint/proc.c    Wed Jun  8 13:52:12 1994
  176. +++ /mymint/proc.c    Sun Jun  5 14:18:02 1994
  177. @@ -701,12 +701,13 @@
  178.  #endif
  179.  }
  180.  
  181. -unsigned long gen_average(sum, cur_load, load_array, ptr, max_size)
  182. -long *sum;
  183. -unsigned long cur_load;
  184. -unsigned char load_array[];
  185. -unsigned long ptr;
  186. -int max_size;
  187. +unsigned long
  188. +gen_average(sum, cur_load, load_array, ptr, max_size)
  189. +    unsigned long *sum;
  190. +    unsigned long cur_load;
  191. +    unsigned char load_array[];
  192. +    unsigned long ptr;
  193. +    int max_size;
  194.  {
  195.      unsigned long retval;
  196.      long old_load, new_load;
  197. @@ -723,7 +724,8 @@
  198.      return retval;
  199.  }
  200.  
  201. -void calc_load_average()
  202. +void
  203. +calc_load_average()
  204.  {
  205.      PROC *p;
  206.  
  207. diff --recursive --unified /mint/procfs.c /mymint/procfs.c
  208. --- /mint/procfs.c    Wed Jun  8 13:52:16 1994
  209. +++ /mymint/procfs.c    Sun Jun  5 14:18:02 1994
  210. @@ -577,7 +577,7 @@
  211.          FILEPTR *pf;
  212.          int pfd = (*(ushort *)buf);
  213.          if (pfd < MIN_HANDLE || pfd >= MAX_OPEN ||
  214. -            !(pf = p->handle[pfd]))
  215. +            0 == (pf = p->handle[pfd]))
  216.              return EIHNDL;
  217.          return (*pf->fc.fs->getxattr)(&pf->fc, (XATTR *)buf);
  218.          }
  219. diff --recursive --unified /mint/proto.h /mymint/proto.h
  220. --- /mint/proto.h    Wed Jun  8 13:52:18 1994
  221. +++ /mymint/proto.h    Sun Jun  5 14:14:02 1994
  222. @@ -260,7 +260,10 @@
  223.  void ARGS_ON_STACK wake P_((int que, long cond));
  224.  void ARGS_ON_STACK wakeselect P_((long param));
  225.  void DUMPPROC P_((void));
  226. +void calc_load_average P_((void));
  227. +unsigned long gen_average P_((unsigned long *sum, unsigned long cur_load, unsigned char load_array[], unsigned long ptr, int max_size));
  228.  
  229. +
  230.  /* signal.c */
  231.  long killgroup P_((int pgrp, int sig));
  232.  void post_sig P_((PROC *p, int sig));
  233. diff --recursive --unified /mint/purec/makefile /mymint/purec/makefile
  234. --- /mint/purec/makefile    Fri Jun 25 20:01:04 1993
  235. +++ /mymint/purec/makefile    Sun Jun  5 14:26:54 1994
  236. @@ -116,24 +116,24 @@
  237.  ATRANSOBJ = asmtab.o trutil.o trans.o
  238.  ATRANS = asmtrans.ttp
  239.  
  240. -$(ATRANS): $(ATRANSOBJ)
  241. -    $(NATIVECC) $(NATIVECFLAGS) -o $(ATRANS) $(ATRANSOBJ) \
  242. -        $(NATIVELIBS)
  243. +#$(ATRANS): $(ATRANSOBJ)
  244. +#    $(NATIVECC) $(NATIVECFLAGS) -o $(ATRANS) $(ATRANSOBJ) \
  245. +#        $(NATIVELIBS)
  246.  
  247. -asmtab.o: asmtab.c asmtrans.h
  248. -    $(NATIVECC) $(NATIVECFLAGS) -o $@ -c asmtab.c
  249. +#asmtab.o: asmtab.c asmtrans.h
  250. +#    $(NATIVECC) $(NATIVECFLAGS) -o $@ -c asmtab.c
  251.  
  252. -trutil.o: trutil.c asmtrans.h
  253. -    $(NATIVECC) $(NATIVECFLAGS) -o $@ -c trutil.c
  254. +#trutil.o: trutil.c asmtrans.h
  255. +#    $(NATIVECC) $(NATIVECFLAGS) -o $@ -c trutil.c
  256.  
  257. -trans.o: trans.c asmtrans.h
  258. -    $(NATIVECC) $(NATIVECFLAGS) -o $@ -c trans.c
  259. +#trans.o: trans.c asmtrans.h
  260. +#    $(NATIVECC) $(NATIVECFLAGS) -o $@ -c trans.c
  261.  
  262.  
  263. -asmtab.c asmtab.h:    asm.y
  264. -    $(YACC) asm.y
  265. -    mv $(YTABC) asmtab.c
  266. -    mv $(YTABH) asmtab.h
  267. +#asmtab.c asmtab.h:    asm.y
  268. +#    $(YACC) asm.y
  269. +#    mv $(YTABC) asmtab.c
  270. +#    mv $(YTABH) asmtab.h
  271.  
  272.  # the magic number include file is generated automagically
  273.  # NOTE that of course, magic.i can only reliably be generated
  274. diff --recursive --unified /mint/purec/mintpure.prj /mymint/purec/mintpure.prj
  275. --- /mint/purec/mintpure.prj    Fri Jun 25 20:00:50 1993
  276. +++ /mymint/purec/mintpure.prj    Sun Jun  5 14:26:30 1994
  277. @@ -1,5 +1,5 @@
  278.  mint.prg
  279. -.C [-DMULTITOS -D__STDC__ -W-stv]
  280. +.C [-DMULTITOS -D__STDC__ -W-stv -P]
  281.  .S [-3 -8 -S]
  282.  =
  283.  PCSTART.O          ; startup code
  284. diff --recursive --unified /mint/purec/osbind.h /mymint/purec/osbind.h
  285. --- /mint/purec/osbind.h    Tue Mar 16 15:46:50 1993
  286. +++ /mymint/purec/osbind.h    Sun Jun  5 14:27:02 1994
  287. @@ -286,7 +286,7 @@
  288.                  int sideno, int interlv, long magic, int virgin );
  289.  void    Midiws( int cnt, void *ptr );
  290.  void    Mfpint( int erno, void (*vector)() );
  291. -IOREC   *Iorec( int dev );
  292. +void    *Iorec( int dev );
  293.  long    Rsconf( int baud, int ctr, int ucr, int rsr, int tsr, int scr );
  294.  KEYTAB  *Keytbl( void *unshift, void *shift, void *capslock );
  295.  long    Random( void );
  296. diff --recursive --unified /mint/purec/puremint.txt /mymint/purec/puremint.txt
  297. --- /mint/purec/puremint.txt    Tue Jul 27 14:39:50 1993
  298. +++ /mymint/purec/puremint.txt    Sun Jun  5 14:26:04 1994
  299. @@ -1,7 +1,7 @@
  300. -How to compile MiNT 1.08 with PureC
  301. +How to compile MiNT 1.11 with PureC
  302.  -----------------------------------
  303.  
  304. -Julian F. Reschke, 25. Juni 1993
  305. +Julian F. Reschke, 5. Juni 1994
  306.  email: reschke@math.uni-muenster.de
  307.  
  308.  
  309. @@ -19,8 +19,8 @@
  310.  directory). I am compiling MiNT with GNU make (latest version at 
  311.  atari.archive.umich.edu should work fine) and a self-made 'cc' command, 
  312.  that I've specially written for the PureC command line versions (see 
  313. -makefile.pcc). This tool is still being tested, and I've not yet decided 
  314. -how to distribute it. If you are interested, write to me.
  315. +makefile.pcc). This tool is available from ftp.uni-muenster.de, 
  316. +pub/atari/Tools/prgtl*.tos.
  317.  
  318.  If you're going to use the PureC shell, you'll have to 'manually' 
  319.  translate the .spp files to the PASM syntax using asmtrans.ttp. The 
  320. diff --recursive --unified /mint/xbios.c /mymint/xbios.c
  321. --- /mint/xbios.c    Wed Jun  8 13:52:36 1994
  322. +++ /mymint/xbios.c    Wed Jun  8 13:59:22 1994
  323. @@ -155,7 +155,6 @@
  324.      long rsval;
  325.      static int oldbaud = -1;
  326.      int ret_oldbaud = 0;
  327. -    IOREC_T *ior;
  328.  
  329.      TRACE(("Rsconf(%d,%d,%d,%d,%d,%d)", baud, flow,
  330.          uc, rs, ts, sc));
  331. @@ -192,7 +191,7 @@
  332.      if (tosvers <= 0x0104) {
  333.          int attempts = 0;
  334.          short old_head;
  335. -        ior = ((IOREC_T *) uiorec(0)) + 1; /* output record */
  336. +        IOREC_T *ior= ((IOREC_T *) uiorec(0)) + 1; /* output record */
  337.          old_head = ior->head;
  338.          while (ior->head != ior->tail) {
  339.              if (++attempts >= 50) { /* prevent getting stuck by flow control */
  340. @@ -273,11 +272,10 @@
  341.      /* (if not, the next line will cause a bus error) */
  342.  #ifdef __TURBOC__
  343.      /* work-around for buggy optimizer */
  344. -        char dummy =
  345. -#endif
  346. -        (void)(*((volatile char *)ptr));
  347. -#ifdef __TURBOC__
  348. +        char dummy = (*((volatile char *)ptr));
  349.          UNUSED(dummy);
  350. +#else
  351. +        (void)(*((volatile char *)ptr));
  352.  #endif
  353.      /* OK, now make sure that interrupt routines will have access,
  354.       * too
  355.  
  356. -- 
  357. ---------------------------------------------------
  358. Julian F. Reschke, Hensenstr. 142, D-48161 Muenster
  359.  eMail: reschke@math.uni-muenster.de jr@ms.maus.de
  360. ___________________________________________________
  361.